<?php

declare (strict_types=1);
namespace Swb\Shop\Model;

use Hyperf\DbConnection\Model\Model as BaseModel;
/**
 * @property int $id 
 * @property string $brand_name 
 * @property int $industry_involved 
 * @property string $business_model 
 * @property string $investment_area 
 * @property string $min_area 
 * @property string $max_area 
 * @property int $franchisee_number 
 * @property int $direct_sales_number 
 * @property string $brand_advantage 
 * @property string $brand_location 
 * @property string $brand_linkman 
 * @property string $brand_phone 
 * @property string $min_cost 
 * @property string $max_cost 
 * @property string $franchise_fee 
 * @property string $cash_deposit 
 * @property string $facility_charge 
 * @property string $other_expenses 
 * @property string $introduce 
 * @property int $hot_push_status 
 * @property string $hot_push_time 
 * @property string $create_by 
 * @property \Carbon\Carbon $created_at 
 * @property string $update_by 
 * @property \Carbon\Carbon $updated_at 
 * @property int $del_flag 
 */
class CBrandAlliance extends BaseModel
{
    /**
     * The table associated with the model.
     *
     * @var string
     */
    protected $table = 'c_brand_alliance';
    /**
     * The attributes that are mass assignable.
     *
     * @var array
     */
    protected $fillable = [];
    /**
     * The attributes that should be cast to native types.
     *
     * @var array
     */
    protected $casts = ['id' => 'string', 'industry_involved' => 'integer', 'franchisee_number' => 'integer', 'direct_sales_number' => 'integer', 'hot_push_status' => 'integer', 'created_at' => 'datetime', 'updated_at' => 'datetime', 'del_flag' => 'integer'];
	protected $keyType='string';
    public function getfile(){
        return $this
            ->belongsTo(File::class,'file_id')
            ->where('del_flag',1)
            ->select('access_path','id');
    }
}